package cn.kilo.types.common;

import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.Getter;

/**
 * @author kilok
 * 微信支付常量类
 */
public class WeChatConstant {
    //mch_id
    public final static String MCH_ID="1677148696";

    //mch_key
    public final static String MCH_KEY="";

    //appid
    public final static String APPID="";

    //secret
    public final static String SECRET="";

    public final static String PRIVATE_KEY_PATH ="";

    //商户证书序列号
    public final static String MERCHANT_SERIAL_NUMBER ="";

    public final static byte[] AES_KEY="".getBytes();



    @Getter
    @AllArgsConstructor
    public enum WeChatHttpRequestHead{

        WXPAY_SIGNATURE("Wechatpay-Signature"),
        WXPAY_SERIAL("Wechatpay-Serial"),
        WXPAY_TIME("Wechatpay-Timestamp"),
        WXPAY_NONCE("Wechatpay-Nonce"),
        ;
        public final String code;
    }

    @Getter
    @AllArgsConstructor
    public enum WeChatPayEnum{
        H5("h5"),
        JSAPI("jsapi"),
        //v3下单
        PAY_TRANSACTIONS("/pay/transactions/"),
        //查询订单
        ORDER_QUERY_BY_NO("/pay/transactions/out-trade-no/"),
        //关闭订单
        CLOSE_ORDER_BY_NO("/pay/transactions/out-trade-no/%s/close"),
        //申请交易订单
        TRADE_BILLS("/bill/tradebill"),
        //申请资金账单
        FUND_FLOW_BILLS("/bill/fundflowbill"),

        ;
        public final String type;
    }
}
